<?php
namespace Minutes\Form;
class TextElement extends InputElement
{
    public function __construct($attributes = array()) {
        $attributes['type'] = 'text';
        parent::__construct($attributes);
    }
    public function render() {
        $output = '<input ';
        foreach ($this->attributes as $name => $value) {
            $output .= $name . '="' . $value . '" ';
        }
        $output .= '>';
        if ($this->error){
            $output = $this->decorateError($output);
        }
        return $output;
    }
}
